import request from "@/utils/request";

// 查询banner列表
export function getList() {
  return request({
    url: "/admin/banner/list",
    method: "get",
  });
}

//上传banner
export function addBanner(data) {
  return request({
    url: "/admin/banner/add",
    method: "post",
    data,
  });
}

//导出banner
export function exportBanner() {
  return request({
    url: "/admin/banner/export",
    method: "get",
  });
}

//删除banner 
export function deleteBnaner(id) {
  return request({
    url: `/admin/banner/remove/${id}`,
    method: "post",
  });
}

//修改
export function editBnaner(data) {
  return request({
    url: `/admin/banner/edit`,
    method: "post",
    data
  });
}